package com.jn.erp.security.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jn.erp.security.entity.SysPermission;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <pre>
 *
 * </pre>
 *
 * @author sunjiyong
 * @since 2024/8/28 15:43
 */
@Mapper
public interface SysPermissionMapper extends BaseMapper<SysPermission> {

    List<String>  selectMenuPermsByRoleId(Long roleId);

    List<String> selectMenuPermsByUserId(Long userId);

    List<SysPermission> selectMenuListByUserId(SysPermission sysPermission);

    int  checkMenuExistRole(Long menuId);

    List<Long> selectMenuListByRoleId(@Param("roleId") Long roleId, @Param("menuCheckStrictly") boolean menuCheckStrictly);
}
